#ifndef STORAGEITEM_H
#define STORAGEITEM_H

#include <QWidget>
#include "storage.h"
#include "sql.h"
namespace Ui {
class StorageItem;
}

class StorageItem : public QWidget
{
    Q_OBJECT

public:
    explicit StorageItem(QWidget *parent = nullptr);
    void update(Storage storage);
    void changeAmount(long amount);
    ~StorageItem();
signals:
    void deleteSignal();
private:
    Ui::StorageItem *ui;
    Storage storage;
    SQL* sql = new SQL();
};

#endif // STORAGEITEM_H
